package com.kelvin.paopao.injector.modules;

import com.kelvin.paopao.adapter.MyAskDateAdapter;
import com.kelvin.paopao.adapter.MyDateAdapter;
import com.kelvin.paopao.injector.PerActivity;
import com.kelvin.paopao.injector.PerFragment;
import com.kelvin.paopao.module.main.date.mydate.myask.IMyAskDatePresenter;
import com.kelvin.paopao.module.main.date.mydate.myask.MyAskDateFragment;
import com.kelvin.paopao.module.main.date.mydate.myask.MyAskDatePresenter;
import com.kelvin.paopao.module.main.date.mydate.mypublish.MyPublishDateFragment;
import com.kelvin.paopao.module.main.date.mydate.mypublish.MyPublishDatePresenter;

import dagger.Module;
import dagger.Provides;

/**
 * Created by Administrator on 2017/5/16.
 */

@Module
public class MyAskDateModule {
    private MyAskDateFragment mView;

    public MyAskDateModule(MyAskDateFragment view) {
        this.mView = view;
    }

    @PerFragment
    @Provides
    public IMyAskDatePresenter providePresenter() {
        return new MyAskDatePresenter(mView);
    }

    @PerFragment
    @Provides
    public MyAskDateAdapter provideAdapter() {
        return new MyAskDateAdapter(mView.getContext());
    }
}
